<?php
namespace app\company\validate;

use think\Validate;

class Comuser extends Validate{

    protected $rule = [
        'name|姓名' =>  'require|max:50',
        'job_number|工号' =>  'require|max:50',
        'account|账号' =>  'require|max:50',
//        'birthday|生日' =>  'require|max:30',
        'department_id|部门' =>  'require|gt:0',
        'mobile|手机号码' =>  'require|length:11',
//        'email|邮箱' =>  'require|email|max:50',
        'entry_time|入职日期' =>  'require',
        'role_id|角色权限' =>  'require|gt:0',
        'cpb_id|奖扣权限' =>  'require'
    ];

    protected $message = [
        'department_id.gt'=>'部门必选',
        'role_id.gt'=>'角色权限必选',
        'cpb_id.gt'=>'奖扣权限必选'
    ];

}